package main

import "fmt"

type person2 struct {
	name string
}

func showPerson(per person2) {
	fmt.Printf("per: %p\n", &per)
	per.name = "kite"
	fmt.Printf("per:: %v\n", per)
}

func showPerson2(per *person2) {
	fmt.Printf("per: %p\n", per)
	per.name = "kite"
	fmt.Printf("per:: %v\n", per)
}

func main() {
	p1 := person2{"tom"}
	fmt.Printf("p1: %p\n", &p1)
	showPerson(p1)
	fmt.Printf("p1: %v\n", p1)
	fmt.Println("------------")
	p2 := &person2{"jack"}
	fmt.Printf("p2: %p\n", p2)
	showPerson2(p2)
	fmt.Printf("p2:%v\n", p2)
}
